FROM centos

ADD oauthadmin-0.0.1-SNAPSHOT.jar /usr/local/
ADD jdk-8u351-linux-x64.tar.gz /usr/local/

ENV MYPATH /usr/local
WORKDIR $MYPATH

ENV JAVA_HOME /usr/local/jdk1.8.0_351
ENV CLASS_PATH $JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
ENV PATH $PATH:$JAVA_HOME/bin

EXPOSE 8888

CMD ["java", "-jar", "oauthadmin-0.0.1-SNAPSHOT.jar"]